package com.bawei.es.domain;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.util.List;
import java.util.Map;

/**
 * @author : zhangyu
 * @date 2023/11/16 21:20
 */
@Data
@Api(tags = "批量插入文档")
public class BulkDocsReq {



        @ApiModelProperty(value = "索引名称",required = true)
        @NotNull(message = "索引名称不能为空")
        private String indexName;

        @ApiModelProperty(value = "文档Id",required = true)
        @NotNull(message = "文档Id不能为空")
        private String documentId;

        @ApiModelProperty(value = "文档信息",required = false)
        @NotNull(message = "文档信息不能为空")
        private List<Map<String,Object>> documentInfo;

        @ApiModelProperty(value = "是否指定文档id",required = false)
        private  boolean isNeedId =false;


}
